<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>美嘉饲料</title>
<meta name="author" content="m.mjpiano.com">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<meta name="format-detection" content="telephone=no">
<meta http-equiv="Expires" CONTENT="-1">
<meta http-equiv="Cache-Control" CONTENT="no-cache">
<meta http-equiv="Pragma" CONTENT="no-cache">
<link rel="stylesheet" href="/m/css/style.css">
<script type="text/javascript" src="<%=basePath%>skin/js/jquery-1.9.1.min.js"></script>
<script type="text/javascript" src="<%=basePath%>m/js/common.js"></script>
</head>
<body>
	<c:import url="/m/layouts/top.jsp" />
	<a name="top"></a>
	<!--header-->
	<header>
	<div class="header">
		<a href="/m/member/index.shtml" class="header-a-back"><span>返回</span></a>
		<a href="/m/index.html" class="header-a-home"><span>首页</span></a>
		<h2>最新订单</h2>
	</div>
	</header>
	<c:choose>
	<c:when test="${empty orders}"></c:when>
	<c:otherwise>
	<c:forEach items="${orders }" var="order">
		<div class="clear10"></div>
		<div class="userdiv clearfix">
			<div class="orderlisttit">
				<p class="fl">
					金额：<span class="fontred">￥<fmt:formatNumber value="${order.amount}" pattern="0.00"/></span>
				</p>
				<p class="fr sfontgrey">下单时间：<fmt:formatDate value="${order.createDate}" pattern="yyyy-MM-dd HH:mm:ss"/></p>
	
			</div>
			<div class="orderlistdiv">
				<a href="<%=basePath%>m/member/order/view.shtml?id=${order.id}" class="ablock orderRlink"> <img
					src="/m/images/pro1.png" class="pro">
					<div class="cart_orderlist_info">
						<p>订单编号：${order.sn }</p>
						<p>
							订单状态：<span class="sfontyellow">${order.orderStatusLabel }</span>
						</p>
					</div>
				</a>
				<div class="orderbtns">
					<c:if test="${order.paymentStatus == 0 && order.orderStatus == 1}">
						<a href="#" class="btn_white_order" id="pay">立即支付</a>
					</c:if>
					<c:if test="${order.paymentStatus == 0}">
						<a href="#" class="btn_white_order" id="cancel">订单取消</a>
					</c:if>
				</div>
				<span class="rightrow"></span>
			</div>
		</div>
	</c:forEach>
	</c:otherwise>
	</c:choose>
	<c:import url="/m/layouts/foot.jsp" />
</body>
</html>
